package com.xiaomili.halfsugar.adapter;

import android.content.Context;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import java.util.List;

/**
 * Created by Administrator on 2016/7/22.
 */
public class CategoryFragmemtPagerAdapter extends FragmentPagerAdapter {
    private Context mContext;
    private List<Fragment> mDatas;

    public CategoryFragmemtPagerAdapter(FragmentManager fm,List<Fragment> datas) {
        super(fm);
        this.mDatas=datas;
    }


    @Override
    public Fragment getItem(int position) {
        return mDatas.get(position);
    }

    @Override
    public int getCount() {
        return mDatas.size();
    }
}
